﻿using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace Simple.Repository.Migrations
{
    public partial class _17 : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AlterColumn<string>(
                name: "ShowRange",
                table: "Slideshow",
                type: "varchar(50)",
                maxLength: 50,
                nullable: true,
                comment: "显示区域1-家长，2-园务",
                oldClrType: typeof(int),
                oldType: "int",
                oldComment: "显示区域1-家长，2-园务")
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AlterColumn<string>(
                name: "ShowRange",
                table: "Article",
                type: "varchar(50)",
                maxLength: 50,
                nullable: true,
                comment: "显示区域 1-家长，2园务",
                oldClrType: typeof(int),
                oldType: "int",
                oldComment: "显示区域 1-家长，2园务")
                .Annotation("MySql:CharSet", "utf8mb4");
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AlterColumn<int>(
                name: "ShowRange",
                table: "Slideshow",
                type: "int",
                nullable: false,
                defaultValue: 0,
                comment: "显示区域1-家长，2-园务",
                oldClrType: typeof(string),
                oldType: "varchar(50)",
                oldMaxLength: 50,
                oldNullable: true,
                oldComment: "显示区域1-家长，2-园务")
                .OldAnnotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AlterColumn<int>(
                name: "ShowRange",
                table: "Article",
                type: "int",
                nullable: false,
                defaultValue: 0,
                comment: "显示区域 1-家长，2园务",
                oldClrType: typeof(string),
                oldType: "varchar(50)",
                oldMaxLength: 50,
                oldNullable: true,
                oldComment: "显示区域 1-家长，2园务")
                .OldAnnotation("MySql:CharSet", "utf8mb4");
        }
    }
}
